--
-- Author: shunguo.chen
-- Date: 2018-06-07 11:54:39
--
-- TheatreMember 大剧院玩家信息

local UserBaseInfo = require("app.public.dao.UserBaseInfo")

local fileName = string.getModeName(...)
local ClassRef = class(fileName)

function ClassRef:ctor(data)
	self.baseInfo = UserBaseInfo.new()
	if data then
		self:init(data)
	end

end

-- // 队员基本信息
-- message Member {
-- base.UserBaseInfo baseInfo = 1;//基本信息
-- int32 pos                  = 2;//玩家位置
-- }
function ClassRef:init(data)
	self.baseInfo:read(data.baseInfo)
	self.baseInfo.mountID = 0

	self.pos = data.pos
end

function ClassRef:getName()
	return self.baseInfo.name
end

function ClassRef:isMe()
	return self.baseInfo.uid == UD:getUid()
end

function ClassRef:getAvatarParams()
	return self.baseInfo
end

return ClassRef